using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using UnityEngine.UI;

public class GameOverPanel : UIPanel
{
    private Button btnTryAgain;
    private void Awake()
    {
        btnTryAgain = transform.Find("Root/AgainButton").GetComponent<Button>();
        btnTryAgain.onClick.AddListener(OnClickBtnTryAgain);
    }

    void OnClickBtnTryAgain()
    {
        Hide();
        GamePanel m_gamePanel = UIManager.Instance.GetPanelByName<GamePanel>();
        m_gamePanel.NewGame();
    }
}
